<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<link rel="stylesheet" href="resources/css/style.css" type="text/css">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>꽁알 : Administrator</title>

<script src="resources/js/jquery-1.9.1.js"></script>
<script type="text/javascript">
function deleteNotice( notice_no ) {
	$.ajax({
		type: "post",
		url: "./deleteNotice.ga",
		data: { notice_no: notice_no },
		dataType: "html",
		success: function( data ) {
			alert("삭제되었습니다.");
			opener.location.href = "./noticeList.ga";
			self.close();
		},
		error: function() {
			alert("삭제되었습니다.");
            opener.location.href = "./noticeList.ga";
            self.close();
		}
	});
}
</script>

</head>
<body>

<table width="300" align="center" cellpadding="20" style="text-align:center;font-size:12pt;">
    <tr>
        <td colspan="2">정말 삭제하시겠습니까?</td>
    </tr>
    <tr>
        <td>
            <input type="button" value="예" onclick="deleteNotice(${notice_no})"
                style="width:100px;height:30px;"
            />
        </td>
        <td>
            <input type="button" value="아니오" onclick="self.close()"
                style="width:100px;height:30px;"
            />
        </td>
    </tr>
</table>

</body>
</html>